package com.yy.pojo;

import java.util.Arrays;
import java.util.List;

public class Teacher {
    private String teacherName;
    private Student student;
    private Course course;

    public void show() {
        System.out.println(this.teacherName + "老师有" +Arrays.toString(student.getStudentName()) + "学生" + "教" + Arrays.toString(this.course.getCourseName())+"课程");
    }

    @Override
    public String toString() {
        return "Teacher{" +
                "teacherName='" + teacherName + '\'' +
                ", student=" + student +
                ", course=" + course +
                '}';
    }

    public String getTeacherName() {
        return teacherName;
    }

    public void setTeacherName(String teacherName) {
        this.teacherName = teacherName;
    }

    public Student getStudent() {
        return student;
    }

    public void setStudent(Student student) {
        this.student = student;
    }

    public Course getCourse() {
        return course;
    }

    public void setCourse(Course course) {
        this.course = course;
    }

    public Teacher(String teacherName, Student student, Course course) {
        this.teacherName = teacherName;
        this.student = student;
        this.course = course;
    }

    public Teacher() {
    }
}
